Release Note
New Features
-
New deserialization support
Added support for deserializing the following transaction types fromraw_data_hex:TransferContractWithdrawBalanceContractWitnessCreateContract
-
trx.getCurrentRefBlockParams
Provides a method to retrieve the parameters required for transaction building. Users can pass these parameters to transaction constructors and customize the header information, making transaction creation more convenient. -
trx.signTypedDataalias
Addedtrx.signTypedDataas an alias pointing to the legacytrx._signTypedDatamethod.
Changes
-
Removed
getHeaderInfofrom thetransactionBuilderhelper library. Usetrx.getCurrentRefBlockParamsinstead. -
Moved the
deserializeTransactionfunction fromutils/transactiontoutils/deserializeTxfor better scalability and maintainability of future modules. -
Dependency updates:
axiosupgraded from 1.11.0 to 1.12.2puppeteerupgraded from 24.4.0 to 24.23.0
Note:
To improve usability and maintain a cleaner structure, we have moved utils.crypto._signTypedData to utils.typedData.signTypedData and relocated constants from utils.address to utils.constants. Here we list the change:
- utils.crypto._signTypedData -> utils.typedData.signTypedData
- utils.address.ADDRESS_SIZE -> utils.constants.ADDRESS_SIZE
- utils.address.ADDRESS_PREFIX -> utils.constants.ADDRESS_PREFIX
- utils.address.ADDRESS_PREFIX_BYTE -> utils.constants.ADDRESS_PREFIX_BYTE
- utils.address.ADDRESS_PREFIX_REGEX -> utils.constants.ADDRESS_PREFIX_REGEX
- utils.address.TRON_BIP39_PATH_PREFIX -> utils.constants.TRON_BIP39_PATH_PREFIX
- utils.address.TRON_BIP39_PATH_INDEX_0 -> utils.constants.TRON_BIP39_PATH_INDEX_0